//
//  SFUnderLBoCollectionViewCell.m
//  GiftThat
//
//  Created by dllo on 16/1/9.
//  Copyright © 2016年 ChuXiang. All rights reserved.
//

#import "SFUnderLBoCollectionViewCell.h"

@implementation SFUnderLBoCollectionViewCell
- (instancetype)initWithFrame:(CGRect)frame
{
    self = [super initWithFrame:frame];
    if (self) {
        self.imageview = [[UIImageView alloc]init];
        [self addSubview:self.imageview];
    }
    return self;
}

-(void)setUnderLBoModel:(SFUnderLBoModel *)UnderLBoModel{
    if (_UnderLBoModel != UnderLBoModel) {
        _UnderLBoModel = UnderLBoModel;
    }

    


    [self.imageview sd_setImageWithURL:[NSURL URLWithString:_UnderLBoModel.image_url]placeholderImage:[UIImage imageNamed:@"holder"]];
    
    
    
    
}
-(void)layoutSubviews{
    [super layoutSubviews];
    self.imageview.frame = self.bounds;
    if ([[[NSUserDefaults standardUserDefaults] objectForKey:@"Color"] isEqualToString:@"BlackColor"]) {
     
        self.backgroundColor = [UIColor colorWithRed:37 / 255.0 green:36 / 255.0 blue:40 / 255.0 alpha:1.0];
        
    }else{
               self.backgroundColor = [UIColor whiteColor];
        
    }
   
}
@end
